<%
/**
 * Copyright (c) 2000-2010 Liferay, Inc. All rights reserved.
 *
 * This library is free software; you can redistribute it and/or modify it under
 * the terms of the GNU Lesser General Public License as published by the Free
 * Software Foundation; either version 2.1 of the License, or (at your option)
 * any later version.
 *
 * This library is distributed in the hope that it will be useful, but WITHOUT
 * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS
 * FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public License for more
 * details.
 */
%>
<aui:script>
    var rc = 1;
   
    function addRow() {      
        var rowid = 'row' + rc;
        var rowx="<div class='" + rowid + "'>";
        rowx += "<input id='file" + rc + "' type='file' name='file0'/>&nbsp;";
        rowx += "&nbsp;";
        rowx += "<img src='/html/themes/control_panel/images/common/add.png' alt='AddColumn' name='addimg' onclick='addRow()'/>&nbsp;";
        rowx += "<img name='delimg' src='/html/themes/control_panel/images/common/delete.png' alt='DelImage'  onclick=\""+"deleteRow('"+rowid+"')\"/>";
        rowx += "<br/><br/></div>";
        AUI().use("aui-node", function(A) {
            var node = A.one('.columnLayout');
            node.append(rowx);
        });
        rc++;
    }
   
    function deleteRow(rowid) {
      AUI().use("aui-node", function(A) {
          var node = A.one('.'+rowid);
          node.remove();
      });
    }
  
</aui:script>
<c:if test="<%= businesscase %>">
		<div class="columnLayout">
		    <div class="row">
		    <label>Supporting Documents</label><br/>
		        <input type="file" name="file0" />
		        <img name='addimg' src='/html/themes/control_panel/images/common/add.png' alt="AddColumn" onclick="addRow();" />
		    </div>
		</div>
</c:if>
<%--

// Override this file to add your own custom fields for file entries.

--%>

<%--
UnicodeProperties extraSettingsProperties = new UnicodeProperties();

if (fileEntry != null) {
	extraSettingsProperties = fileEntry.getExtraSettingsProperties();
}
--%>

<%--<tr>
	<td class="lfr-label">
		<liferay-ui:message key="author" />
	</td>
	<td>
		<input name="extraSettingsProperties--author--" style="width: <%= ModelHintsConstants.TEXT_DISPLAY_WIDTH %>px;" type="text" value="<%= GetterUtil.getString(extraSettingsProperties.getProperty("author")) %>" />
	</td>
</tr>
<tr>
	<td class="lfr-label">
		<liferay-ui:message key="type" />
	</td>
	<td>
		<input name="extraSettingsProperties--type--" style="width: <%= ModelHintsConstants.TEXT_DISPLAY_WIDTH %>px;" type="text" value="<%= GetterUtil.getString(extraSettingsProperties.getProperty("type")) %>" />
	</td>
</tr>--%>